﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ArchivesProcess.aspx.cs"
    Inherits="TrafficArchives.Archives.ArchivesProcess" %>

<%@ Register TagPrefix="custom" TagName="Pager" Src="~/Controls/Pager.ascx" %>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <link href="../css/Page.css" rel="stylesheet" type="text/css" />
    <link href="../css/GamerGridView.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <asp:ScriptManager ID="ScriptManager1" runat="server">
    </asp:ScriptManager>
    <script language="javascript" type="text/javascript">
        function checkAll(host) {
            var obj = document.getElementsByTagName("input");

            for (var i = 0; i < obj.length; i++) {
                if ((obj[i].tagName.toLocaleLowerCase() == "input")
                    && obj[i].type.toLocaleLowerCase() == "checkbox") {
                    obj[i].checked = host.checked;
                }
            }
        }

        function confirmCanel() {
            var obj = document.getElementsByTagName("input");
            var count = 0;
            for (var i = 0; i < obj.length; i++) {
                if ((obj[i].tagName.toLocaleLowerCase() == "input")
                    && obj[i].type.toLocaleLowerCase() == "checkbox") {
                    if (obj[i].checked) {
                        count++;
                    }
                }
            }
            if (count == 0) {
                alert("请选择数据行。");
                return false;
            }
            if (confirm("确认要取消所选的信誉档案吗？")) {
                return true;
            }
            return false;
        }
    </script>
    <table width="100%" height="100%" border="0" cellpadding="0" cellspacing="2" bgcolor="#acd1eb"
        style="font-size: 12px;">
        <tr>
            <td valign="top" bgcolor="#FFFFFF">
                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                    <tr>
                        <td>
                            <table width="100%" border="0" cellspacing="0" cellpadding="0">
                                <tr style="background: url(../images/bt_bg.gif)">
                                    <td width="12">
                                        <img src="../images/bt_left.gif" width="12" height="28">
                                    </td>
                                    <td width="42" align="center">
                                        <img src="../images/bt_title.gif">
                                    </td>
                                    <td style="font-size: 12px;">
                                        <span class="style3">您当前的位置：</span>信誉档案处理
                                    </td>
                                    <td width="51" id="sy">
                                        <a href="../Reports/ArchivesOverview.aspx">首页</a>
                                    </td>
                                    <td width="12">
                                        <img src="../images/bt_right.gif" width="12" height="28">
                                    </td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                    <tr>
                        <td align="center" height="30">
                            <!--查询begin-->
                            <table width="95%" border="0" cellspacing="1" cellpadding="0" bgcolor="#CCCCCC">
                                <tr bgcolor="#FFFFFF">
                                    <td width="10%" height="30" align="right" bgcolor="#E4F1FD">
                                        <span class="style4">身份证号：</span>
                                    </td>
                                    <td width="15%">
                                        <asp:TextBox ID="TxtIdentityNo" CssClass="inputText wid100_2" runat="server" />
                                    </td>
                                    <td width="10%" align="right" bgcolor="#E4F1FD">
                                        <span class="style4">档案编号：</span>
                                    </td>
                                    <td width="15%" align="left">
                                        <asp:TextBox ID="TxtArchiveNo" CssClass="inputText wid100_2" runat="server" />
                                    </td>
                                    <td width="50%" align="left">
                                        <asp:Button ID="BtnQuery" OnClick="BtnQueryClicked" Text="查询" runat="server" CssClass="button" />
                                    </td>
                                </tr>
                            </table>
                            <!--查询over-->
                        </td>
                    </tr>
                    <tr>
                        <td align="center" valign="top">
                            <!--详细信息begin-->
                            <!--详细信息over-->
                            <table width="95%" border="0" cellspacing="0" cellpadding="0">
                                <tr>
                                    <td height="15">
                                    </td>
                                </tr>
                            </table>
                            <asp:UpdatePanel ID="UpdatePanelMain" UpdateMode="Conditional" runat="server">
                                <ContentTemplate>
                                    
                                    <!--信誉档案begin-->
                                    <table width="95%" id="TableHeader" runat="server" border="0" class="GridViewStyle"
                                        cellpadding="0" cellspacing="0">
                                        <tr>
                                            <th align="center" class="HeaderStyle">
                                            </th>
                                            <th align="center" class="HeaderStyle">
                                                姓名
                                            </th>
                                            <th align="center" class="HeaderStyle">
                                                驾驶证号
                                            </th>
                                            <th align="center" class="HeaderStyle">
                                                准驾车型
                                            </th>
                                            <th align="center" class="HeaderStyle">
                                                记录时间
                                            </th>
                                            <th align="center" class="HeaderStyle">
                                                信誉种类
                                            </th>
                                            <th align="center" class="HeaderStyle">
                                                内容
                                            </th>
                                            <th align="center" class="HeaderStyle">
                                                操作
                                            </th>
                                        </tr>
                                    </table>
                                    <asp:GridView ID="GridViewMain" runat="server" Width="95%" AllowPaging="False" AllowSorting="True"
                                    OnRowCommand="GridViewMainRowCommand"
                                        AutoGenerateColumns="False" CssClass="GridViewStyle" DataKeyNames="XYDATABLE_ID"
                                        GridLines="None">
                                        <Columns>
                                            <asp:TemplateField HeaderText="操作">
                                                <ItemTemplate>
                                                    <asp:CheckBox ID="ChkRow" runat="server" />
                                                </ItemTemplate>
                                            </asp:TemplateField>
                                            <asp:BoundField HeaderText="姓名" DataField="NAME" />
                                            <asp:BoundField HeaderText="驾驶证号" DataField="ZJCODE" />
                                            <asp:BoundField HeaderText="准驾车型" DataField="ZJCODE" />
                                            <asp:BoundField HeaderText="记录时间" DataField="RECODETIME" />
                                            <asp:BoundField HeaderText="信誉种类" DataField="XYTYPENAME" />
                                            <asp:BoundField HeaderText="内容" DataField="CONTENT" />
                                            <asp:TemplateField HeaderText="操作">
                                                <ItemTemplate>
                                                    <div class="linkButton">
                                                        <asp:LinkButton ID="BtnLook" Text="查 看" CommandArgument='<%#Eval("XYDATABLE_ID") %>' CommandName="Look" CssClass="edit" runat="server" />
                                                    </div>
                                                    <div class="linkButton">
                                                        <asp:LinkButton ID="BtnModify" Text="修 改" CommandArgument='<%#Eval("XYDATABLE_ID") %>' CommandName="Modify" CssClass="edit" runat="server" />
                                                    </div>
                                                </ItemTemplate>
                                            </asp:TemplateField>
                                        </Columns>
                                        <FooterStyle CssClass="FooterStyle" />
                                        <RowStyle CssClass="RowStyle" />
                                        <EmptyDataRowStyle CssClass="EmptyRowStyle" />
                                        <SelectedRowStyle CssClass="SelectedRowStyle" />
                                        <HeaderStyle CssClass="HeaderStyle" />
                                        <EditRowStyle CssClass="EditRowStyle" />
                                        <AlternatingRowStyle CssClass="AltRowStyle" />
                                    </asp:GridView>
                                    <table width="95%" border="0" cellspacing="0" cellpadding="0" style="font-size: 12px;
                                        height: 30; background-color: #E4F1FD">
                                        <tr>
                                            <td width="70" align="center">
                                                <label>
                                                    <input type="checkbox" onclick="checkAll(this)" name="checkbox2" id="checkbox2" />
                                                    全选
                                                </label>
                                            </td>
                                            <td width="100" id="csh1" valign="middle">
                                                <div id="DivModify" class="linkButton">
                                                    <asp:LinkButton ID="BtnCancel" OnClick="BtnCancelClicked" Text="取消信誉报告" CssClass="edit"
                                                        runat="server" />
                                                </div>
                                            </td>
                                            <td width="*">
                                                &nbsp;
                                            </td>
                                        </tr>
                                    </table>
                                    <div style="font-size: 11px; width: 95%">
                                        <custom:Pager ID="MainPager" runat="server" OnPageIndexChanged="MainPagerPageIndexChanged" />
                                    </div>
                                </ContentTemplate>
                            </asp:UpdatePanel>
                            <!--信誉档案over-->
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
    </table>
    </form>
</body>
</html>
